package day03;

import java.util.Scanner;

public class Exercise03 {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int x = sc.nextInt();
        int y = sc.nextInt();
        System.out.println("最大值" + MAX(x, y));
        System.out.println("最小值" + MIN(x, y));
        int year = sc.nextInt();
        System.out.println(year + "年" + LeapYear(year));
        double point = sc.nextDouble();
        System.out.println(Rank(point));

    }

    public static int MAX(int a, int b) {//最大值
//        int Max = a>b?a:b;
        if (a > b)
            return a;
        else
            return b;

    }

    public static int MIN(int x, int y) {//最小值
//        int min = x<y?x:y;
//        return min;
        if (x > y)
            return y;
        else
            return x;
    }

    public static String LeapYear(int year) {//判断闰年
        if (year % 4 == 0 && year % 100 != 0 || year % 400 == 0) {
            return "是闰年";
        } else {
            return "不是闰年";
        }

    }

    public static String Rank(double point) {//打分
        if (point < 0 || point > 100)
            return "非法";
        else if (point >= 90)
            return "A等";
        else if (point >= 80)
            return "B等";
        else if (point >= 60)
            return "C等";
        else
            return "D等";

    }

}
